import request from '@/utils/request'

// 巡检计划列表
export function inspectionPlansList(data) {
  return request({
    url: 'v1/inspection-plans/index',
    method: 'get',
    params: {
      ...data
    }
  })
}

// 巡检计划-新增
export function inspectionPlansAdd(data) {
  return request({
    url: 'v1/inspection-plans/create',
    method: 'post',
    data: data
  })
}

// 巡检计划-修改
export function inspectionPlansUpdate(data) {
  return request({
    url: 'v1/inspection-plans/update',
    method: 'post',
    params: {
      plan_id: data.plan_id
    },
    data: data
  })
}

// 巡检计划模板列表
export function inspectionTemplatePlansList(data) {
  return request({
    url: 'v1/inspection-plans/template',
    method: 'get',
    params: {
      ...data
    }
  })
}
